import mongoose from 'mongoose';

const HotSearchSchema = new mongoose.Schema(
  {
    book: { type: mongoose.Schema.Types.ObjectId, ref: 'Book' }, // 书籍
    recommend_text: String, // 推荐理由
    priority: Number, // 显示优先级
    create_time: Date
  },
  { versionKey: false }
);

const HotSearch = mongoose.model('HotSearch', HotSearchSchema);

export { HotSearch };
